package com.bw.kf.all2211a.fg

import android.content.Intent
import androidx.navigation.fragment.NavHostFragment
import androidx.navigation.ui.setupWithNavController
import com.alibaba.android.arouter.facade.annotation.Route
import com.blankj.utilcode.util.ToastUtils
import com.bw.kf.all2211a.R
import com.bw.kf.all2211a.databinding.ActivityHomeBinding
import com.bw.kf.all2211a.fg.fgviewModel.MIneViewMode
import com.bw.kf.all2211a.fg.fgviewModel.ResetActivity
import com.bw.kf.mvvm.base.BaseActivity
import com.bw.kf.mvvm.base.BaseViewActivity
@Route(path = "/app/fg/HomeActivity")
class HomeActivity : BaseViewActivity<ActivityHomeBinding>() {
    override fun iniView() {
//        viewModel.getUser()
//        binding.reset.setOnClickListener {
//            startActivity(Intent(this@HomeActivity,ResetActivity::class.java))
//        }
        val navHostFragment=supportFragmentManager.findFragmentById(R.id.fragmentContainerView) as NavHostFragment
        val navController=navHostFragment.navController
        binding.bottom.setupWithNavController(navController)
    }

    override fun iniData() {
//        viewModel.success.observe(this){
//            if (it.code==200){
//               binding.info=it.data
//            }
//            ToastUtils.showLong(it.message)
//        }

    }
    override fun Layoutid()=R.layout.activity_home
}